<div class="box static-banners <?php echo $hide_on_mobile_class; ?>" style="<?php echo isset($css) ? $css : ''; ?>">
    <div>
    <?php if ($title): ?>
    <div class="box-heading"><?php echo $title; ?></div>
    <?php endif; ?>
<?php foreach ($sections as $section): ?>
    <div class="static-banner <?php echo $grid_classes; ?>">
        <?php if ($section['link']): ?>
        <?php if($section['link'] == 'facebook'){?>
        
         <a id="fb-banner"  href="#"><img style="<?php echo $image_border; ?>" src="<?php echo $section['content']; ?>" alt="" /></a>
        
        <?php }else{?>
        <a  href="<?php echo $section['link']; ?>" <?php echo $section['target']; ?>><img style="<?php echo $image_border; ?>" src="<?php echo $section['content']; ?>" alt="" /></a>
        
        <?php }?>
        <?php else: ?>
        <img style="<?php echo $image_border; ?>" src="<?php echo $section['content']; ?>" alt="" />
        <?php endif; ?>
    </div>
<?php endforeach; ?>
    </div>
    
  
  
  <div id="fb-popup">
  	<div id="fb-popup-content">	
    </div>
  </div>
   <script>
      $("#fb-banner").click(function(){
		  $("#fb-popup-content").html('<iframe scrolling="no" width="100%" height="100%"  src="fbapp/index.php"></iframe>');
		  $("#fb-popup").fadeIn(300);
		  
		  });
		  
	 $("#fb-popup").click(function(){
		 
		  $("#fb-popup").fadeOut(300);
		 
	});
   </script>
</div>

  
    